#ifndef ALERTNOTICE_H
#define ALERTNOTICE_H

#include <QWidget>
#include "../MainProject/sqlitedatabase.h"
#include <QSqlTableModel>
#include "../MainProject/loggermanager.h"
#include "../MainProject/common.h"
namespace Ui {
class AlertNotice;
}

class AlertNotice : public QWidget
{
    Q_OBJECT

public:
    explicit AlertNotice(QWidget *parent = nullptr);
    ~AlertNotice();

public slots:
    void onSaveBtnClick();
    void onRefreshBtnClick();
     void onTableDoubleClicked(const QModelIndex &index);

private:
    void setupModel();
    void setupConnections();

private:
    Ui::AlertNotice *ui;
    QSqlTableModel *model;
    SQLiteDatabase* db;
    Common common;
};

#endif // ALERTNOTICE_H
